﻿using System;
using System.Collections.Generic;
using CloudPms.Entity.Entities;

namespace CloudPms.Common.CacheInterface
{
    /// <summary>
    /// 房间信息缓存存储与更新接口
    /// <para>--------------------------</para>
    /// <para>@Author: cnalexi@gmail.com</para> 
    /// <para>@Create: 2012/10/06</para>  
    /// <example>
    /// <code>
    /// var rcStore = container.Resolve[IRoomCacheStore>();//container是UnityIOC容器
    /// </code>
    /// </example> 
    /// </summary>
    public interface IRoomCacheStore
    {
        string GetCacheKey(string hotelId);

        /// <summary>
        /// 批量添加房间进缓存
        /// </summary>
        /// <param name="hotelId"></param>
        /// <param name="hotelRooms"></param>
        void BatchSet(string hotelId, IEnumerable<Room> hotelRooms);
        IList<Room> BatchGet(string hotelId);
        IList<Room> BatchGet(string hotelId, DateTime modifiedTime);
        Room Get(string hotelId,string roomNo);
        DateTime GetCacheTime(string hotelId);
    }
}